# Copyright 2019 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# NOTE: This file is auto generated by the elixir code generator program.
# Do not edit this file manually.

defmodule GoogleApi.CSS.V1.Model.Account do
  @moduledoc """
  Information about CSS/MC account.

  ## Attributes

  *   `accountType` (*type:* `String.t`, *default:* `nil`) - Output only. The type of this account.
  *   `automaticLabelIds` (*type:* `list(String.t)`, *default:* `nil`) - Automatically created label IDs assigned to the MC account by CSS Center.
  *   `displayName` (*type:* `String.t`, *default:* `nil`) - The CSS/MC account's short display name.
  *   `fullName` (*type:* `String.t`, *default:* `nil`) - Output only. Immutable. The CSS/MC account's full name.
  *   `homepageUri` (*type:* `String.t`, *default:* `nil`) - Output only. Immutable. The CSS/MC account's homepage.
  *   `labelIds` (*type:* `list(String.t)`, *default:* `nil`) - Manually created label IDs assigned to the CSS/MC account by a CSS parent account.
  *   `name` (*type:* `String.t`, *default:* `nil`) - The label resource name. Format: accounts/{account}
  *   `parent` (*type:* `String.t`, *default:* `nil`) - The CSS/MC account's parent resource. CSS group for CSS domains; CSS domain for MC accounts. Returned only if the user has access to the parent account.
  """

  use GoogleApi.Gax.ModelBase

  @type t :: %__MODULE__{
          :accountType => String.t() | nil,
          :automaticLabelIds => list(String.t()) | nil,
          :displayName => String.t() | nil,
          :fullName => String.t() | nil,
          :homepageUri => String.t() | nil,
          :labelIds => list(String.t()) | nil,
          :name => String.t() | nil,
          :parent => String.t() | nil
        }

  field(:accountType)
  field(:automaticLabelIds, type: :list)
  field(:displayName)
  field(:fullName)
  field(:homepageUri)
  field(:labelIds, type: :list)
  field(:name)
  field(:parent)
end

defimpl Poison.Decoder, for: GoogleApi.CSS.V1.Model.Account do
  def decode(value, options) do
    GoogleApi.CSS.V1.Model.Account.decode(value, options)
  end
end

defimpl Poison.Encoder, for: GoogleApi.CSS.V1.Model.Account do
  def encode(value, options) do
    GoogleApi.Gax.ModelBase.encode(value, options)
  end
end
